home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_08_11
/
8n11034a
< prev
next >
Wrap
Text File
|
1990-09-17
|
459b
|
29 lines
#include <stdio.h>
#include <stdlib.h>
main()
{
char filename[21];
char env_var[21];
char path[61];
while (scanf("%20s %20s", filename, env_var) != EOF) {
_searchenv(filename, env_var, path);
if (*path == '\0')
printf("no such file\n");
else
printf("path is >%s<\n", path);
}
}
link.exe path
no such file
link.exe PATH
path is >c:\dos\link.exe<
LINK.exe PATH
path is >c:\dos\LINK.exe<
dummy PATH
no such file